*::after,
*::before {
  box-sizing: border-box;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  overflow-x: hidden;
  min-height: 100vh;
  background: #f5f8ff;
  display: flex;
  justify-content: center;
  align-items: center;
}

.container {
    margin: 0 40px;
    max-width: 600px;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.container h1 {
    color: #333;
}

.container .tab {
    position: relative;
    background: #FFF;
    padding: 0 20px 20px;
    box-shadow: 0 15px 15px rgba(0,0,0,.05);
    border-radius: 5px;
    overflow: hidden;
}

.container .tab input {
    appearance: none;
}

.container .tab label {
    display: flex;
    align-items: center;
    cursor: pointer;
}

.container .tab label::after {
    content: '+';
    position: absolute;
    right: 20px;
    font-size: 1.4em;
    color: rgba(0,0,0,0.1);
    transition: transform 1s;
}

.container .tab:hover label::after {
    color: #333;
}

.container .tab input:checked ~ label::after {
    transform: rotate(135deg);
    color: #FFF;
}

.container .tab label h2 {
    width: 40px;
    height: 40px;
    background: #333;
    display: flex;
    justify-content: center;
    align-items: center;
    color: #FFF;
    font-size: 1.25em;
    border-radius: 5px;
    margin-right: 10px;
}

.container .tab label h3 {
    position: relative;
    font-weight: 500;
    color: #333;
    z-index: 10;
}

.container .tab .content {
    max-height: 0;
    transition: 1s;
    overflow: hidden;
}

.container .tab input:checked ~ .content {
    max-height: 100vh;
}

.container .tab .content p {
    position: relative;
    padding: 10px 0;
    color: #333;
    z-index: 10;
    line-height: 25px;
}

.container .tab:nth-child(2) label h2 {
    background: linear-gradient(135deg, #70f570, #49c628);
}

.container .tab:nth-child(3) label h2 {
    background: linear-gradient(135deg, #3c8ce7, #00eaff);
}

.container .tab:nth-child(4) label h2 {
    background: linear-gradient(135deg, #ff96f9, #c32bac);
}

.container .tab:nth-child(5) label h2 {
    background: linear-gradient(135deg, #fd6e6a, #ffc600);
}

.container .tab input:checked ~ label h2 {
    position: absolute;
    top: 0 ;
    left: 0;
    width: 100%;
    height: 100%;
    color: rgba(255,255,255,.2);
    font-size: 8em;
    justify-content: flex-end;
    padding: 20px;
}

.container .tab input:checked ~ label h3 {
    background: #fff;
    padding: 4px 15px;
    color: #333;
    border-radius: 4px;
    box-shadow: 0 5px 15px rgba(0,0,0,.05);
}

.container .tab input:checked ~ .content p {
    color: #Fff;
}